// pages/qa/rz/index.js
var a,b
var app = getApp();  
Page({

  /**
   * 页面的初始数据
   */
  data: {
xming:'',
xhing:'',
    timu:app.globalData.allqsxs
  },

  /**
   * 生命周期函数--监听页面加载
   */
  onLoad: function (options) {

  },

  /**
   * 生命周期函数--监听页面初次渲染完成
   */
  onReady: function () {

  },

  /**
   * 生命周期函数--监听页面显示
   */
  onShow: function () {
    this.setData({
      timu: app.globalData.allqsxs

    })

  },

  /**
   * 生命周期函数--监听页面隐藏
   */
  onHide: function () {

  },

  /**
   * 生命周期函数--监听页面卸载
   */
  onUnload: function () {

  },

  /**
   * 页面相关事件处理函数--监听用户下拉动作
   */
  onPullDownRefresh: function () {

  },

  /**
   * 页面上拉触底事件的处理函数
   */
  onReachBottom: function () {

  },

  /**
   * 用户点击右上角分享
   */
  onShareAppMessage: function () {

  },
  gotoPage2: function () {

    wx.navigateTo({ url: 'school', })
  }, 
  xm: function (e) {
    //console.log(e)
    this.setData({

      xming: e.detail.value
    })
    a = e.detail.value
    console.log(e)
  }, xh: function (e) {
    //console.log(e)
    this.setData({

      xhing: e.detail.value
    })
    b = e.detail.value
    console.log(e.detail.value)
  },




  rz: function () {
var bj=0

//以下为认证信息
if(a=='张峻巍'&&b=='2016214345')bj=1  //0为未认证，1为本校，2为外校
    if (a == '刘明' && b == '0501170113') bj = 2
    if (a == '李秋悦' && b == '1001190304') bj = 2
    if (a == '何双甫' && b == '0703180110') bj = 2
    if (a == '毕晨琪' && b == '0501180107') bj = 2
    if (a == '陈洋洋' && b == '1001190221') bj = 2
    if (a == '刘海伦' && b == '5021190121') bj = 2
    if (a == '张月馨' && b == '1001190302') bj = 2
    if (a == '范文博' && b == '3024190428') bj = 2
    if (a == '李嘉懿' && b == '1804190320') bj = 2
    if (a == '马海菠' && b == '4025190116') bj = 2
    if (a == '王秉国' && b == '2018212707') bj = 1
    if (a == '郭骁琛' && b == '2019212628') bj = 1
    if (a == '苏杨' && b == '2019222470') bj = 1
    if (a == '华中瑀' && b == '2019210066') bj = 1
    if (a == '赵婉越' && b == '2018221977') bj = 1
    if (a == '曾泓铭' && b == '2019213096') bj = 1
    if (a == '施承昊' && b == '2019210616') bj = 1
    if (a == '乔一南' && b == '2019213193') bj = 1
    if (a == '郭家均' && b == '2019213192') bj = 1
    if (a == '刘增辉' && b == '2019211064') bj = 1
    if (a == '王紫琛' && b == '2016212991') bj = 1
    if (a == '王浩杰' && b == '2016210782') bj = 1
    if (a == '陈绍华' && b == '2019211315') bj = 1
    if (a == '姬鸿远' && b == '1190101914') bj = 2
    if (a == '郝洁' && b == '1192320110') bj = 2
    if (a == '张驰' && b == '1190501110') bj = 2
    if (a == '刘泳' && b == '1190501111') bj = 2
    if (a == '王超凡' && b == '1190501109') bj = 2
    if (a == '高萌' && b == '1190102323') bj = 2
    if (a == '田宪儒' && b == '1190302204') bj = 2
    if (a == '辛帅' && b == '1190201909') bj = 2
    if (a == '陈泽宇' && b == '1190201908') bj = 2
    if (a == '解虹丹' && b == '1191001011') bj = 2
    if (a == '陈文灏' && b == '1190301618') bj = 2
    if (a == '朱玉鹏' && b == '1190101008') bj = 2
    if (a == '王翘楚' && b == '1191510107') bj = 2
    if (a == '张腾' && b == '1190302924') bj = 2
    if (a == '王迪' && b == '1190201523') bj = 2
    if (a == '邓首昆' && b == '1190302212') bj = 2
    if (a == '徐为' && b == '1190201304') bj = 2
    if (a == '李贤' && b == '1190500415') bj = 2
    if (a == '尹嘉奇' && b == '1190302624') bj = 2
    if (a == '姜桦' && b == '1190102124') bj = 2
    if (a == '林思琪' && b == '1190501314') bj = 2
    if (a == '林翰永' && b == '1190500809') bj = 2
    if (a == '付颖祎' && b == '1190600207') bj = 2
    if (a == '谭立' && b == '1190300526') bj = 2
    if (a == '刘笑非' && b == '1190303219') bj = 2
    if (a == '姜伟' && b == '1190301123') bj = 2
    if (a == '苏贝克' && b == '1191520215') bj = 2
    if (a == '陈刚' && b == '1190400905') bj = 2
    if (a == '唐博睿' && b == '1190100710') bj = 2
    if (a == '欧阳晨璐' && b == '1191000602') bj = 2
    if (a == '张淏柃' && b == '1191000720') bj = 2
    if (a == '张磊' && b == '1192800104') bj = 2
    if (a == '薛健' && b == '1190303427') bj = 2
    if (a == '肖福鸿' && b == '1190101807') bj = 2
    if (a == '孔德沄' && b == '1190600124') bj = 2
    if (a == '黄皓琪' && b == '1190100906') bj = 2
    if (a == '杜子明' && b == '1190100910') bj = 2
    if (a == '冯星阳' && b == '1190301315') bj = 2
    if (a == '张怡慧' && b == '1192800205') bj = 2
    if (a == '宋克强' && b == '1190201415') bj = 2
    if (a == '胡娟' && b == '1190400719') bj = 2
    if (a == '陈嘉宁' && b == '1190102304') bj = 2
    if (a == '邹锐' && b == '1190100719') bj = 2
    if (a == '于茧佩' && b == '1190300628') bj = 2
    if (a == '李想' && b == '1190201520') bj = 2
    if (a == '尹纪龙' && b == '1182800115') bj = 2
    if (a == '刘聪' && b == '1190302203') bj = 2
    if (a == '安杨' && b == '1190302115') bj = 2
    if (a == '张迈' && b == '1190201919') bj = 2
    if (a == '万学尧' && b == '1190500124') bj = 2
    if (a == '陈曦' && b == '1190501205') bj = 2
    if (a == '张凡' && b == '1190100209') bj = 2
    if (a == '李哲宇' && b == '1190202218') bj = 2
    if (a == '吴天' && b == '1190100723') bj = 2
    if (a == '张永轩' && b == '1190100717') bj = 2
    if (a == '陈泽林' && b == '1190101721') bj = 2
    if (a == '宋佳雨' && b == '1190400913') bj = 2
    if (a == '孙弘' && b == '1190400909') bj = 2
    if (a == '张跃政' && b == '1190400904') bj = 2
    if (a == '蒙勇志' && b == '1190302116') bj = 2
    if (a == '昕鹏' && b == '1190500418') bj = 2
    if (a == '陈晨曦' && b == '1190100828') bj = 2
    if (a == '孙仲硕' && b == '1190100417') bj = 2
    if (a == '谷文博' && b == '1190100414') bj = 2
    if (a == '杨小泽' && b == '1190300322') bj = 2
    if (a == '徐博涛' && b == '1190300619') bj = 2
    if (a == '左永泰' && b == '1190300527') bj = 2
    if (a == '李康乐' && b == '1190303114') bj = 2
    if (a == '王越' && b == '1190303111') bj = 2
    if (a == '杨丰泽' && b == '1190201804') bj = 2
    if (a == '钱家乐' && b == '1190300803') bj = 2
    if (a == '蒋孟格' && b == '1190302713') bj = 2
    if (a == '官正中' && b == '1190400306') bj = 2
    if (a == '涂鑫泊' && b == '1190201223') bj = 2
    if (a == '林凯洋' && b == '1190201306') bj = 2
    if (a == '刘荣山' && b == '1190501522') bj = 2
    if (a == '罗屹华' && b == '1190200207') bj = 2
    if (a == '王城臻' && b == '1190201822') bj = 2
    if (a == '刘一帆' && b == '1190302925') bj = 2
    if (a == '徐杭镔' && b == '1190400901') bj = 2
    if (a == '杨贤航' && b == '1190200825') bj = 2
    if (a == '何颖凤' && b == '1190303627') bj = 2
    if (a == '赵博超' && b == '1190600118') bj = 2
    if (a == '郭宇颖' && b == '1190100625') bj = 2
    if (a == '刘翌' && b == '1190100421') bj = 2
    if (a == '陈岩松' && b == '1190400415') bj = 2
    if (a == '郭一鸣' && b == '1190101120') bj = 2
    if (a == '王欢' && b == '1190501225') bj = 2
    if (a == '金聖娟' && b == 'L191630102') bj = 2
    if (a == '吴和煦' && b == '1190101417') bj = 2
    if (a == '王禹琦' && b == '1190202113') bj = 2
    if (a == '冯博雅' && b == '1190501307') bj = 2
    if (a == '郑逸杰' && b == '1190301620') bj = 2
    if (a == '王一凡' && b == '1190100517') bj = 2
    if (a == '熊阳' && b == '1190300116') bj = 2
    if (a == '胡潮' && b == '1190501910') bj = 2
    if (a == '饶熙辰' && b == '1190401112') bj = 2
    if (a == '康钦豪' && b == '1190302015') bj = 2
    if (a == '谢奥' && b == '1190201922') bj = 2
    if (a == '许卓璠' && b == '1190100518') bj = 2
    if (a == '王景' && b == '1190302823') bj = 2
    if (a == '王飞扬' && b == '1190200314') bj = 2
    if (a == '杨伯毓' && b == '1190101427') bj = 2
    if (a == '陈广焕' && b == '1190501614') bj = 2
    if (a == '吕振山' && b == '1190400418') bj = 2
    if (a == '王亦楷' && b == '1190300926') bj = 2
    if (a == '梅国干' && b == '1190101913') bj = 2
    if (a == '胡志超' && b == '1170201928') bj = 2
    if (a == '刘梓桐' && b == '1190201928') bj = 2
    if (a == '陈天星' && b == '1190102102') bj = 2
    if (a == '刘晓倩' && b == '1190101723') bj = 2
    if (a == '徐芷含' && b == '1190501906') bj = 2
    if (a == '郭磊' && b == '1190401116') bj = 2
    if (a == '宋迪' && b == '1190101112') bj = 2
    if (a == '敖佳雨' && b == '1190101704') bj = 2
    if (a == '张森' && b == '1190201920') bj = 2
    if (a == '陈伟霖' && b == '1190201917') bj = 2
    if (a == '李祯' && b == '1190102206') bj = 2
    if (a == '樊红雨' && b == '1190201816') bj = 2
    if (a == '张诗鹭' && b == '1190301410') bj = 2
    if (a == '李星辰' && b == '1190400823') bj = 2
    if (a == '杨世钰' && b == '1190400718') bj = 2
    if (a == '黎智坤' && b == '1190201911') bj = 2
    if (a == '杨浩淼' && b == '1190201905') bj = 2
    if (a == '黄岩峰' && b == '1190400120') bj = 2
    if (a == '黄菁菁' && b == '1190100611') bj = 2
    if (a == '冶繁' && b == '1190600321') bj = 2
    if (a == '郭雨萌' && b == '1190501924') bj = 2
    if (a == '艾孜麦提江' && b == '1190501913') bj = 2
    if (a == '于东辉' && b == '1190301413') bj = 2
    if (a == '孟子晴' && b == '1191520103') bj = 2
    if (a == '郝敬伟' && b == '1190400715') bj = 2
    if (a == '杜晓莉' && b == '1182620115') bj = 2
    if (a == '何子祎' && b == '1190301629') bj = 2
    if (a == '杨芷轶' && b == '1190301629') bj = 2
    if (a == '侯楚晗' && b == '1190301728') bj = 2
    if (a == '刘航' && b == '1190301802') bj = 2
    if (a == '张奕鸣' && b == '1190303309') bj = 2
    if (a == '叶柯' && b == '1190500306') bj = 2
    if (a == '张松林' && b == '1190400303') bj = 2
    if (a == '王鹏程' && b == '1190600313') bj = 2
    if (a == '邓祥' && b == '1190300204') bj = 2
    if (a == '李益乾' && b == '1190200814') bj = 2
    if (a == '肖剑' && b == '19SD33269') bj = 2
    if (a == '陈思佳' && b == '1191000904') bj = 2
    if (a == '邓旭航' && b == '1190500317') bj = 2
    if (a == '斐晓松' && b == '1190201614') bj = 2
    if (a == '王红杰' && b == '1190201108') bj = 2
    if (a == '肖宇航' && b == '1190300406') bj = 2
    if (a == '黎雪松' && b == '1190100109') bj = 2
    if (a == '王文浩' && b == '1190101112') bj = 2
    if (a == '屈舒天' && b == '1190303517') bj = 2
    if (a == '宋志远' && b == '1190100721') bj = 2
    if (a == '耿涛' && b == '1190300621') bj = 2
    if (a == '杨文昊' && b == '1190303027') bj = 2
    if (a == '康钦豪' && b == '1190302015') bj = 2
    if (a == '宋欣哲' && b == '1190600120') bj = 2
    if (a == '邓轶斌' && b == '1190400307') bj = 2
    if (a == '屈舒天' && b == '1190303517') bj = 2
    if (a == '马皓宇' && b == '1190100526') bj = 2
    if (a == '文耀夫' && b == '1190401117') bj = 2
    if (a == '袁金斗' && b == '1190200209') bj = 2
    if (a == '王亦楷' && b == '1190300926') bj = 2
    if (a == '舒振家' && b == '1190201311') bj = 2
    if (a == '徐华成' && b == '1190101725') bj = 2
    if (a == '徐程' && b == '1190101918') bj = 2
    if (a == '唐丽淇' && b == '1190100524') bj = 2
    if (a == '冯星阳' && b == '1190301315') bj = 2
    if (a == '吴浩田' && b == '1190201208') bj = 2
    if (a == '许卓璠' && b == '1190100518') bj = 2
    if (a == '邹锐' && b == '1190100719') bj = 2
    if (a == '尹纪龙' && b == '1182800115') bj = 2
    if (a == '冀梓灿' && b == '1190303125') bj = 2
    if (a == '刘子阳' && b == '1190101717') bj = 2
    if (a == '库德热提' && b == '1190101204') bj = 2
    if (a == '任勇行' && b == '1190600106') bj = 2
    if (a == '杨富强' && b == '1190100921') bj = 2
    if (a == '陈冠洋' && b == '1180500516') bj = 2
    if (a == '宋迪' && b == '1190101701') bj = 2
    if (a == '何虹林' && b == '1190301118') bj = 2
    if (a == '石毓剑' && b == '1190101402') bj = 2
    if (a == '徐鸿皓' && b == '1190400622') bj = 2
    if (a == '危波' && b == '1190101727') bj = 2
    if (a == '范佳乐' && b == '1190201613') bj = 2
    if (a == '王纪言' && b == '1190502223') bj = 2
    if (a == '朱千喜' && b == '1182700310') bj = 2
    if (a == '周思琪' && b == '1181820305') bj = 2
    if (a == '盛伟岩' && b == '1161100206') bj = 2
    if (a == '杨锦程' && b == '1161910104') bj = 2
    if (a == '林天宇' && b == '19S006008') bj = 2
    if (a == '刘鑫' && b == '1170801011') bj = 2
    if (a == '杨郁昂' && b == '1173300809') bj = 2
    if (a == '张云鹏' && b == '1171000606') bj = 2
    if (a == '罗紫蕊' && b == '1173300609') bj = 2
    if (a == '吕浩' && b == '1170100203') bj = 2
    if (a == '朱畅' && b == '1170700108') bj = 2
    if (a == '刘沸阳' && b == '1180200615') bj = 2
    if (a == '茹天翔' && b == '1181400520') bj = 2
    if (a == '唐佳辰' && b == '1180400112') bj = 2
    if (a == '段文博' && b == '1160910311') bj = 2
    if (a == '王博仟' && b == '1150240326') bj = 2
    if (a == '唐斌' && b == '1180400513') bj = 2
    if (a == '胡云潇' && b == '') bj = 2
    if (a == '张磊' && b == '1192800104') bj = 2
    if (a == '文飞洋' && b == '1173000205') bj = 2
    if (a == '李博' && b == '1170400508') bj = 2
    if (a == '张正卿' && b == '1171820207') bj = 2
    if (a == '刘观文' && b == '1181820214') bj = 2
    if (a == '王志诚' && b == '1181820415') bj = 2
    if (a == '张雪颖' && b == '1181820316') bj = 2
    if (a == '叶华辰' && b == '1180801007') bj = 2
    if (a == '辛正莹' && b == '1182100325') bj = 2
    if (a == '方远行' && b == '1180501010') bj = 2
    if (a == '赵泽明' && b == '1180610602') bj = 2
    if (a == '刘旭' && b == '1180200421') bj = 2
    if (a == '段朝心' && b == '1180800305') bj = 2
    if (a == '吴骄阳' && b == '1180801301') bj = 2
    if (a == '黄皓琪' && b == '1190100906') bj = 2
    if (a == '高文博' && b == '1192800212') bj = 2
    if (a == '高影' && b == '1171820317') bj = 2
    if (a == '张淏柃' && b == '1191000720') bj = 2
    if (a == '赖琪' && b == '201930003') bj = 2
    if (a == '曾培凯' && b == '201927012') bj = 2
    if (a == '杜沐晓' && b == '201926021') bj = 2
    if (a == '邵汉' && b == '201929031') bj = 2
    if (a == '任斌' && b == '201928109') bj = 2
    if (a == '沈先亮' && b == '201928013') bj = 2
    if (a == '刘传玮' && b == '201926044') bj = 2
    if (a == '王泽洲' && b == '201923079') bj = 2
    if (a == '孔文昊' && b == '201925054') bj = 2
    if (a == '王耀' && b == '201925001') bj = 2
    if (a == '刘相琪' && b == '201925052') bj = 2
    if (a == '欧阳嘉宏' && b == '201927135') bj = 2
    if (a == '陈宇宣' && b == '201934021') bj = 2
    if (a == '邵弘毅' && b == '201930016') bj = 2
    if (a == '李颖欣' && b == '201927210') bj = 2
    if (a == '沈芳' && b == '2017222335') bj = 1
    if (a == '张瑜' && b == '2017223930') bj = 1












    if (app.globalData.rz == 1 || app.globalData.rz == 2) {
      wx.showModal({
        content: "您已经认证，本次打开无需重复认证",
        title: "已认证",
        showCancel: false,
        success: function (res) {
          if (res.confirm) {
            console.log('用户点击确定')
          }
        }
      })
      wx.navigateBack({
        delta: 1,

      })
    }

    else {
      if (bj == 1) {
        app.globalData.allqs = 1010//认证之后题目数量
        app.globalData.allqsxs = 1010//用户可以看到的数字
        app.globalData.rz = 1//已认证
        wx.showModal({
          content: "您已经可以使用全部题库！（请注意，下次打开仍需要进行认证）",
          title: "认证成功！",
          showCancel: false,
          success: function (res) {
            if (res.confirm) {
              console.log('用户点击确定')
            }
          }
        })
        this.setData({
          timu: app.globalData.allqs

        })
        wx.navigateBack({
          delta: 1,

        })
      } else if (bj == 2){
        app.globalData.allqs = 200 //认证之后实际题目数量
        app.globalData.allqsxs = 1010//用户可以看到的数字
        app.globalData.rz = 2//已认证
        wx.showModal({
          content: "您已经可以使用全部题库！（请注意，下次打开仍需要进行认证）",
          title: "认证成功！",
          showCancel: false,
          success: function (res) {
            if (res.confirm) {
              console.log('用户点击确定')
            }
          }
        })
        this.setData({
          timu: app.globalData.allqs

        })
        wx.navigateBack({
          delta: 1,

        })
        
      }
      
      
      else {
        wx.showModal({
          content: "不存在此用户，请联系学校管理员核对。",
          title: "认证失败！",
          showCancel: false,
          success: function (res) {
            if (res.confirm) {
              console.log('用户点击确定')
            }
          }
        })

      }


    }


 



  }, 
})